import {WalletFAQComponent} from './wallet/faq/faq.component';
import {NgModule} from '@angular/core';
import {RouterModule, Routes} from "@angular/router";
import {MineComponent} from "@mine/mine.component";

import {AddressComponent} from "@mine/address/address.component";
import {AddressListComponent} from "@mine/address/address-list/address-list.component";
import {AddressFormComponent} from './address/address-form/address-form.component';
import {MassageComponent} from "@mine/massage/massage.component";
import {NoticeComponent} from "@mine/massage/notice/notice.component";
import {EditInfoComponent} from '@mine/edit-info/edit-info.component';
import {EditDetailComponent} from '@mine/edit-info/edit-detail/edit-detail';
import {AreaPickerComponent} from '@mine/edit-info/area-picker/area-picker.component';
import {InfoComponent} from '@mine/content/info/info.component';
import {DiggComponent} from '@mine/content/digg/digg.component';

import {WalletComponent} from './wallet/wallet.component';
import {BillComponent} from './wallet/bill/bill.component';
import {PortalComponent} from './wallet/portal/portal.component';
import {MoreComponent} from "@mine/more/more.component";
import {CollectComponent} from "@mine/collect/collect.component";
import {AuthenticationComponent} from "@mine/authentication/authentication.component";
import {MineResolver} from "@mine/mine.resolver";
import {GrantComponent} from "@mine/grant/grant.component";
import {SettingComponent} from "@mine/setting/setting.component";
import {AboutComponent} from "@mine/setting/about/about.component";

const routes: Routes = [
  {
    path: '',
    component: MineComponent,
    resolve: {
      profile: MineResolver
    },
    data: {
      meta: {
        title: '求苗票务_体育赛事门票在线预订_体育比赛门票网上订购平台',
        keywords: '体育门票,赛事订票,比赛门票订购,体育票务网站',
        description: `求苗票务频道为您全方位提供各类体育赛事票务网上预订、门票在线订购服务!`,
      },
    },
  },
  {
    path: 'message',
    component: MassageComponent,
  },
  {
    path: 'message/:noticeType',
    component: NoticeComponent,
  },
  {
    path: 'setting',
    component: SettingComponent
  },
  {
    path: 'setting/profile',
    component: EditInfoComponent
  },
  {
    path: 'setting/about',
    component: AboutComponent
  },
  {
    path: 'setting/edit',
    component: EditDetailComponent,
  },
  {
    path: 'choose-city',
    component: AreaPickerComponent,
  },
  {
    path: 'info',
    component: InfoComponent,
  },
  {
    path: 'digg',
    component: DiggComponent,
  },
  {
    path: 'feed',
    redirectTo: '/feed'
  },
  {
    path: 'address',
    component: AddressComponent,
    children: [
      {
        path: '',
        redirectTo: 'list',
        pathMatch: 'full',
      },
      {
        path: 'list',
        component: AddressListComponent
      },
      {
        path: 'form',
        component: AddressFormComponent
      }
    ]
  },
  {
    path: 'more',
    component: MoreComponent
  },
  {
    path: 'grant/:orgUserId',
    component: GrantComponent
  },
  {
    path: 'authentication',
    component: AuthenticationComponent
  },
  {
    path: 'wallet',
    component: WalletComponent,
    children: [
      {
        path: '',
        redirectTo: 'portal',
        pathMatch: 'full',
      },
      {
        path: 'portal',
        component: PortalComponent
      },
      {
        path: 'bill',
        component: BillComponent
      },
      {
        path: 'faq',
        component: WalletFAQComponent
      }
    ]
  },
  {
    path: 'collect',
    component: CollectComponent
  }

];

@NgModule({
  imports: [
    RouterModule.forChild(routes)
  ],
  exports: [RouterModule],

})
export class MineRoutingModule {
}
